/*
 * ﻿Copyright (C) 2013 NewMain Softech
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
 * either express or implied. See the License for the specific language
 * governing permissions and limitations under the License.
 */
package com.newmainsoftech.eatestutil.container.glassfish;

import java.util.Map.Entry;

import com.newmainsoftech.eatestutil.container.InstalledLocalContainerWrapper;

/**
 * Contracts for unique properties to configure embedded glassfish.<br />
 * 
 * @author Arata Y.
 */
public interface EmbeddedGlassfishPropertyConfig {
	public final static String EmbeddedGlassfishConfigurationFilePropertyKey 
	= "org.glassfish.ejb.embedded.glassfish.configuration.file";
	/**
	 * Generates an <code>Entry</code> instance for the {@value #EmbeddedGlassfishConfigurationFilePropertyKey} 
	 * property.<br />
	 * The <code>Entry</code> instance being returned can be used to add to map object being given to 
	 * <code>EJBContainer.createEJBContainer</code> method.<br />
	 * 
	 * @return Entry instance for {@value #EmbeddedGlassfishConfigurationFilePropertyKey} property.
	 */
	Entry<String, Object> getEmbeddedGlassfishConfigurationFilePropertyEntry( String configurationFilePath);
	
	public final static String EmbeddedGlassfishInstallationRootPropertyKey 
	= "org.glassfish.ejb.embedded.glassfish.installation.root";
	/**
	 * Getter of an <code>Entry</code> instance for the {@value #EmbeddedGlassfishInstallationRootPropertyKey} 
	 * property.<br />
	 * The <code>Entry</code> instance being returned can be used to add to map object being given to 
	 * <code>EJBContainer.createEJBContainer</code> method.<br />
	 * 
	 * @return Entry instance for {@value #EmbeddedGlassfishInstallationRootPropertyKey} property.
	 */
	Entry<String, Object> getEmbeddedGlassfishInstallationRootPropertyEntry( 
			InstalledLocalContainerWrapper installedLocalContainerWrapper);
	
	public final static String EmbeddedGlassfishInstanceRootPropertyKey 
	= "org.glassfish.ejb.embedded.glassfish.instance.root";
	/**
	 * Generates an <code>Entry</code> instance for the {@value #EmbeddedGlassfishInstanceRootPropertyKey} 
	 * property.<br />
	 * The <code>Entry</code> instance being returned can be used to add to map object being given to 
	 * <code>EJBContainer.createEJBContainer</code> method.<br />
	 * 
	 * @return Entry instance for {@value #EmbeddedGlassfishInstanceRootPropertyKey} property.
	 */
	Entry<String, Object> getEmbeddedGlassfishInstanceRootPropertyEntry( String instanceRootDirPath);
	
	public final static String EmbeddedGlassfishWebHttpPortPropertyKey 
	= "org.glassfish.ejb.embedded.glassfish.web.http.port";
	/**
	 * Generates an <code>Entry</code> instance for the {@value #EmbeddedGlassfishWebHttpPortPropertyKey} 
	 * property.<br />
	 * The <code>Entry</code> instance being returned can be used to add to map object being given to 
	 * <code>EJBContainer.createEJBContainer</code> method.<br />
	 * 
	 * @return Entry instance for {@value #EmbeddedGlassfishWebHttpPortPropertyKey} property.
	 */
	Entry<String, Object> getEmbeddedGlassfishWebHttpPortPropertyEntry( String port);
	
	public final static String KeepTemporaryFilesSystemPropertyKey 
	= "org.glassfish.ejb.embedded.keep-temporary-files";
	/**
	 * Setter for {@value #KeepTemporaryFilesSystemPropertyKey} system property.<br />
	 */
	void setKeepTemporaryFiles( boolean keep);
}